public class Employee {

    private String name;
    private Integer age;
    private Department department;

    public Employee() {
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public Department getDepartment() {
        return department;
    }

    public void setDepartment(Department department) {
        this.department = department;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    static class Department{
        private String name;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }
    }

    public static void main(String[] args) {
        Employee emp = new Employee();
        emp.setAge(13);
        emp.setName("老齐");
        Department d = new Department();
        d.setName("小卖部");
        emp.setDepartment(d);
        emp.setJoke("一言不合就开车");
    }

    private void setJoke(String content) {
        System.out.println(this.getName() + "说" + content);
    }
}
